package com.logistics.pick.entity.model;

import com.logistics.material.entity.model.MaterialBackSave;
import com.logistics.utils.bean.SaveBasic;
import lombok.Data;

@Data
public class PickSave extends SaveBasic {
    // id
    private String id;

    // 单号
    private String code;

    // 状态
    private String status;

    private String pickCode;

    private String station;

    private String containerCode;
    // 托盘编号
    private String containerId;

//    private String erpInvBillType;

    public PickSave(){};

    public static PickSave build(String id,String code,String status,String pickCode,String station,String containerCode,String containerId){
        PickSave pickSave = new PickSave();
        pickSave.setId(id);
        pickSave.setCode(code);
        pickSave.setStatus(status);
        pickSave.setPickCode(pickCode);
        pickSave.setStation(station);
//        pickSave.setErpInvbillCode(erpInvbillCode);
        pickSave.setContainerCode(containerCode);
        pickSave.setContainerId(containerId);
        return pickSave;
    }

    public static PickSave build(MaterialBackSave save, String status){
        PickSave pickSave = new PickSave();
        pickSave.setContainerCode(save.getContainer());
//        pickSave.setErpInvbillCode(save.getErpInvBillCode());
        pickSave.setStation(save.getStation());
        pickSave.setStatus(status);
//        pickSave.setErpInvBillType(erpInvBillType);
        return pickSave;
    }
}
